package com.igelato.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

import com.baomidou.mybatisplus.annotation.TableField;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import lombok.Data;
    import lombok.experimental.Accessors;


/**
 * @TableName: user
 * @Description:
 * @Author: wht
 * @Date: 2024-01-25
 */
@Data
    @Accessors(chain = true)
public class User implements Serializable{
                @TableId(value = "id", type = IdType.AUTO)
                private Integer id;
        @ApiModelProperty("微信的openid，为了兼容支付宝小程序、app等，所以openid可以为空。")
        private String openid;
        private String nickname;
        @ApiModelProperty("用户余额")
        private Integer amount;
        @ApiModelProperty("积分")
        private Integer bonus_points;
        private String avatar;
        @ApiModelProperty("由于这里的手机号是从微信上获取到的，所以不确定有多少个字节，所有类型使用varchar。并且用户在小程序上登录也不用手机号，所以就没给它加唯一索引。")
        private String mobile;
        private LocalDate birthday;
        @ApiModelProperty("1：男；2：女；")
        private Byte gender;
        @ApiModelProperty("1：正常；-1：已冻结；-99：已注销；")
        private Byte status;
        private LocalDateTime create_time;
        private LocalDateTime update_time;

        @TableField(exist = false)
        private List<Coupon> couponList;
@TableField(exist = false)
private static final long serialVersionUID=1L;

        }
